//
//  NetworkCommand.h
//  ZhangJiangJun
//
//  Created by FENGYL on 2017/1/18.
//  Copyright © 2017年 FENGYL. All rights reserved.
//

#import <Foundation/Foundation.h>

@interface NetworkCommand : NSObject

/**
 登录
 **/
+(void)userLoginUserName:(NSString *)userName password:(NSString *)password success:(void(^)())success failure:(void(^)())failure;

/**
 获取所以设备
 **/
+(void)getDeviceListSuccess:(void(^)())success failure:(void(^)())failure;

/**
 获取时间段内警报(notification专用,取一整天)
 **/
+(void)getHistoryEventDataByTime:(NSDate *)date serialNumber:(NSString *)serialNumber success:(void(^)())success failure:(void(^)())failure;

/**
 上锁解锁
 **/
+(void)stampIsUnlock:(BOOL)isUnlock stampCount:(NSString *)stampCount time:(NSString *)time success:(void(^)())success failure:(void(^)())failure;

/**
 获取报警地点
 **/
+(void)getDeviceLocationByTime:(NSDate *)date Success:(void (^)())success failure:(void (^)())failure;

/**
 获取指定机身号的属性
 **/
+(void)getDeviceAttrsOfSuccess:(void (^)())success failure:(void (^)())failure;

/**
 批量获取最后状态信息
 **/
+(void)getLastStatusDataForSerialNumber:(NSString *)serialNumber Success:(void (^)(NSArray *responseObject))success failure:(void (^)())failure;

/**
 获取多个设备的最后数据点
 **/
+(void)getLastTrackPoiDataBySnsForSerialNumber:(NSString *)serialNumber Success:(void (^)(NSArray *responseObject))success failure:(void (^)())failure;

/**
 获取单个设备的时间段数据
 **/
+(void)getHistoryTrackPoiDataByTimeForStartTime:(NSString *)startTime EndTime:(NSString *)endTime Success:(void (^)(NSArray *responseObject))success failure:(void (^)())failure;

/**
 获取与此设备绑定的所有围栏
 **/
+(void)GetGeoFencesByDeviceForSerialNumber:(NSString *)serialNumber Success:(void (^)(NSArray *responseObject))success failure:(void (^)())failure;

/**
 提交围栏
 **/
+(void)PutGeoFenceForPoints:(NSString *)points fenceName:(NSString *)fenceName fenceId:(NSNumber *)fenceId Success:(void (^)(id responseObject))success failure:(void (^)())failure;

/**
 为设备绑定围栏
 **/
+(void)BindForBindFenceId:(NSNumber *)bindFenceId ZoneType:(NSNumber *)zoneType isEnter:(NSNumber *)isEnter isLeave:(NSNumber *)isLeave displayName:(NSString *)displayName serialNumber:(NSString *)serialNumber Success:(void (^)(id responseObject))success failure:(void (^)())failure;

/**
 为设备解除对某个围栏的绑定
 **/
+(void)UnBindForBindFenceId:(NSNumber *)bindFenceId ZoneType:(NSNumber *)zoneType isEnter:(NSNumber *)isEnter isLeave:(NSNumber *)isLeave displayName:(NSString *)displayName serialNumber:(NSString *)serialNumber Success:(void (^)(id responseObject))success failure:(void (^)())failure;

/**
 删除围栏
 **/
+(void)DelGeoFenceForPoints:(NSString *)points fenceName:(NSString *)fenceName fenceId:(NSNumber *)fenceId Success:(void (^)(id responseObject))success failure:(void (^)())failure;

/**
 时间戳转换时间(dd/MM/yyyy 23:59:59)
 **/
+(NSString *)getEndOfDayTimeStringForDate:(NSDate *)date;

/**
 时间戳转换date
 **/
+(NSDate *)TimestampChangeDate:(NSString *)timestamp;

/**
 时间戳转换时间(HH:mm:ss)
 **/
+ (NSString *)TimestampChangeTimestr:(NSString *)Timestamp;

/**
 时间戳转换时间(dd/MM/yyyy HH:mm:ss)
 **/
+(NSString *)getTimeStringForTimeStamp:(NSNumber *)timeStamp;

/**
 根据日期和时间返回时间戳
 **/
+(NSNumber *)getTimeStampForDateString:(NSString *)dateString;




+ (NSString *)getUniqueStrByUUID;

@end
